#include <bits/stdc++.h>
using namespace std;

char *__abc147, *__xyz258, __ma369[100000];
#define __hv007() ((__abc147==__xyz258) && (__xyz258=(__abc147=__ma369)+fread(__ma369,1,100000,stdin),__abc147==__xyz258) ? EOF : *__abc147++)

int getUnsigned(){
	char ch = __hv007();
	while( ch < '0' || ch > '9' ) ch = __hv007();

	int ret = (int)(ch-'0');
	while( '0' <= ( ch = __hv007() ) && ch <= '9' ) ret = (ret<<1) + (ret<<3) + (int)(ch-'0');
	return ret;
}

#define fi first
#define se second

int const G[][2] = {{2,3},{5,7},{9,12},{11,15},{14,20},{17,22},{24,32},{19,33},{26,35},{31,38},{29,40},{42,52},{37,53},{28,58},{45,60},{50,62},{47,65},{55,68},{49,70},{44,75},{57,79},{67,86},{64,87},{72,92},{74,99},{77,101},{83,110},{85,113},{90,116},{82,118},{89,123},{97,126},{95,127},{94,129},{103,136},{108,145},{106,146},{139,156},{122,160},{120,161},{125,164},{112,166},{81,174},{133,177},{138,180},{132,182},{143,186},{142,190},{149,195},{152,197},{135,198},{105,199},{148,203},{168,215},{158,218},{172,224},{171,228},{163,229},{154,232},{185,236},{141,239},{192,241},{115,246},{184,253},{194,256},{189,259},{208,264},{201,266},{188,268},{210,271},{207,274},{214,278},{221,280},{205,281},{170,286},{217,289},{179,298},{226,301},{252,305},{248,306},{234,307},{131,309},{245,313},{223,315},{213,317},{250,321},{212,322},{244,325},{220,327},{231,332},{255,339},{151,340},{261,346},{176,350},{276,358},{263,359},{285,362},{293,367},{283,370},{238,372},{270,375},{288,379},{296,386},{295,390},{243,391},{319,408},{312,411},{303,415},{300,432},{329,435},{345,445},{343,446},{338,449},{334,454},{291,456},{352,461},{311,464},{349,467},{384,470},{395,474},{361,478},{357,479},{400,483},{388,485},{399,487},{337,489},{364,494},{342,496},{324,501},{377,505},{374,509},{397,511},{393,518},{369,520},{273,521},{423,525},{366,527},{421,529},{407,530},{405,531},{356,532},{413,537},{420,541},{336,545},{434,549},{382,553},{443,556},{419,557},{348,558},{427,560},{258,565},{410,568},{431,570},{437,574},{355,577},{425,580},{417,586},{402,588},{354,590},{460,596},{440,600},{404,601},{439,603},{469,610},{448,614},{453,620},{430,624},{473,632},{492,635},{381,639},{499,646},{508,648},{504,649},{452,651},{503,653},{516,658},{481,660},{463,661},{515,664},{466,666},{459,671},{498,673},{442,683},{477,691},{564,693},{551,697},{331,702},{555,711},{514,716},{429,719},{595,722},{543,723},{491,726},{540,735},{567,737},{523,740},{572,744},{585,748},{539,752},{476,760},{472,761},{576,766},{583,768},{563,771},{458,772},{513,776},{634,778},{579,780},{628,785},{619,787},{507,788},{626,799},{548,800},{594,805},{607,810},{593,811},{622,818},{617,822},{547,825},{644,827},{599,828},{616,831},{630,836},{612,842},{606,845},{609,849},{535,855},{676,857},{605,866},{685,869},{663,870},{451,871},{657,876},{592,877},{637,879},{695,883},{641,886},{710,892},{534,893},{680,896},{643,899},{679,904},{706,910},{678,912},{730,917},{656,918},{689,920},{732,924},{669,929},{714,935},{700,937},{751,944},{699,946},{704,948},{794,956},{708,957},{687,964},{718,969},{721,976},{750,982},{675,985},{582,986},{668,989},{763,991},{757,995},{713,996},{747,1000},{743,1007},{728,1010},{756,1013},{774,1017},{754,1020},{797,1023},{796,1029},{782,1032},{742,1036},{765,1038},{816,1040},{655,1046},{833,1053},{864,1055},{791,1061},{739,1062},{746,1065},{824,1070},{803,1072},{853,1076},{808,1079},{807,1081},{790,1082},{784,1085},{793,1090},{830,1098},{875,1102},{852,1106},{682,1107},{815,1110},{814,1117},{813,1118},{848,1120},{835,1122},{863,1130},{820,1131},{859,1145},{770,1150},{868,1156},{885,1164},{839,1165},{734,1167},{882,1175},{862,1180},{890,1186},{851,1190},{888,1192},{881,1194},{838,1201},{562,1202},{861,1206},{906,1208},{902,1211},{874,1212},{915,1214},{943,1219},{847,1225},{898,1227},{909,1231},{844,1241},{927,1243},{914,1245},{973,1248},{954,1254},{908,1261},{950,1265},{940,1268},{923,1269},{931,1274},{967,1279},{978,1284},{895,1285},{1027,1292},{963,1295},{960,1297},{972,1302},{933,1307},{959,1311},{952,1314},{984,1317},{841,1322},{994,1329},{1051,1331},{1043,1334},{1002,1336},{971,1337},{1006,1346},{981,1348},{725,1358},{1012,1361},{926,1363},{1009,1366},{1035,1371},{999,1372},{1025,1376},{993,1378},{942,1381},{873,1384},{1045,1387},{1034,1389},{966,1390},{922,1394},{1089,1397},{1005,1400},{1144,1403},{939,1405},{1060,1408},{1069,1413},{1058,1414},{1019,1419},{962,1420},{1100,1425},{1078,1428},{1016,1432},{1140,1438},{1096,1443},{1064,1446},{1125,1449},{988,1451},{1094,1455},{1088,1457},{1048,1458},{1004,1461},{1104,1464},{1015,1465},{1092,1468},{1143,1470},{1022,1477},{1109,1481},{1116,1484},{1174,1491},{1075,1492},{1087,1499},{1137,1502},{1134,1509},{1124,1510},{1074,1514},{1129,1516},{1068,1521},{1161,1525},{1042,1527},{1159,1529},{1136,1532},{1155,1534},{1153,1536},{1139,1537},{1113,1539},{1152,1541},{1067,1543},{980,1547},{1183,1560},{1169,1561},{1142,1563},{1158,1569},{1133,1575},{1178,1577},{1239,1580},{1149,1581},{1197,1590},{1163,1592},{598,1599},{1247,1605},{1112,1606},{1188,1611},{1171,1612},{1229,1617},{1173,1619},{1238,1622},{1217,1625},{1127,1626},{1031,1633},{1200,1636},{1221,1640},{1237,1643},{1236,1651},{1199,1653},{1258,1661},{1283,1664},{1185,1665},{1148,1674},{1235,1678},{1204,1679},{1281,1682},{1290,1684},{1084,1687},{1278,1692},{1276,1694},{1057,1695},{1289,1702},{1272,1707},{1260,1708},{1301,1710},{1264,1713},{1224,1717},{1253,1721},{1327,1729},{1233,1730},{1216,1736},{1251,1746},{1320,1754},{1300,1756},{1115,1758},{1357,1762},{1305,1765},{1316,1767},{1263,1769},{1418,1772},{1310,1774},{802,1777},{1344,1782},{1340,1785},{1325,1787},{1267,1795},{1257,1799},{1343,1802},{1319,1811},{998,1812},{1250,1820},{1339,1822},{1380,1824},{1304,1825},{1354,1831},{1309,1832},{1430,1837},{1360,1838},{1352,1842},{1299,1845},{1416,1847},{1342,1850},{759,1854},{1370,1859},{1392,1863},{1294,1866},{1442,1869},{1410,1877},{1369,1878},{1365,1879},{1287,1882},{1368,1884},{1356,1888},{1396,1901},{1386,1904},{1196,1906},{1407,1914},{1383,1919},{1475,1922},{1437,1923},{1223,1929},{1422,1935},{1480,1941},{1472,1942},{1460,1947},{1448,1949},{1436,1953},{1495,1964},{1402,1966},{1505,1970},{1520,1972},{1434,1975},{1399,1978},{1508,1981},{1504,1986},{1494,1992},{1441,1994},{1497,1997},{1571,2001},{1507,2003},{1271,2004},{1453,2007},{1463,2011},{901,2018},{1487,2026},{1555,2029},{1490,2030},{1479,2031},{1554,2033},{1375,2036},{1424,2040},{1412,2042},{1566,2050},{1440,2051},{1546,2056},{1524,2059},{1565,2067},{1551,2070},{1531,2076},{1177,2077},{1589,2080},{1597,2085},{1513,2088},{1550,2094},{1518,2096},{1501,2098},{1588,2100},{1579,2103},{1568,2105},{1489,2107},{1557,2116},{1553,2129},{1704,2132},{1483,2134},{1587,2137},{1333,2140},{1604,2142},{1630,2145},{1586,2148},{1603,2152},{1574,2161},{1741,2163},{1594,2168},{1670,2174},{1616,2176},{1584,2180},{1657,2182},{1621,2184},{1512,2191},{1663,2193},{1628,2194},{1601,2195},{1614,2198},{1673,2202},{1610,2203},{1474,2205},{1445,2209},{1256,2215},{1659,2217},{1691,2222},{1642,2224},{1638,2229},{1467,2230},{1701,2234},{1690,2237},{1650,2239},{1712,2246},{1751,2254},{1648,2255},{1573,2256},{1700,2261},{1699,2268},{1681,2271},{1647,2276},{1609,2281},{1728,2283},{1706,2287},{1351,2288},{1672,2293},{1698,2297},{1646,2298},{1635,2302},{1655,2310},{1761,2317},{1745,2318},{1724,2322},{1608,2329},{1805,2332},{1726,2335},{1583,2338},{1719,2341},{1753,2345},{1676,2347},{1744,2350},{1669,2356},{1790,2358},{1743,2362},{1814,2365},{1668,2366},{1723,2368},{1050,2369},{1798,2375},{1732,2376},{1776,2381},{1781,2385},{1324,2388},{1545,2390},{1792,2393},{1873,2395},{1818,2398},{1817,2400},{1789,2402},{1794,2404},{1764,2406},{1780,2411},{1830,2415},{1808,2420},{1549,2421},{1760,2426},{1738,2427},{1807,2435},{1689,2437},{1716,2439},{1858,2444},{1784,2449},{1749,2453},{1210,2455},{1835,2459},{1891,2462},{1828,2469},{1810,2473},{1849,2485},{1740,2490},{1927,2492},{1844,2493},{1735,2495},{1876,2502},{1871,2505},{1909,2509},{1897,2511},{1865,2513},{1900,2515},{1804,2516},{1841,2523},{1890,2525},{1913,2530},{1771,2538},{1989,2546},{1940,2548},{1926,2549},{1925,2550},{1857,2551},{2013,2556},{1779,2557},{1911,2564},{1903,2567},{1938,2570},{1894,2572},{1917,2575},{1881,2576},{1916,2592},{1937,2597},{1899,2600},{1147,2604},{1715,2607},{1974,2611},{1862,2613},{1959,2616},{1182,2623},{2039,2627},{1958,2632},{1834,2634},{1667,2640},{1934,2642},{1983,2645},{1956,2647},{1486,2657},{1944,2661},{1933,2665},{2048,2668},{1624,2669},{2025,2671},{1977,2673},{1955,2675},{2009,2682},{2016,2684},{1988,2687},{1952,2689},{1969,2691},{1932,2700},{2021,2702},{1999,2704},{1991,2707},{1921,2708},{1896,2709},{1856,2720},{2015,2729},{2058,2733},{1985,2738},{1893,2743},{2092,2746},{2055,2747},{2047,2749},{1840,2751},{2066,2754},{2111,2758},{2062,2759},{1963,2761},{2091,2768},{1886,2773},{2128,2778},{2023,2779},{1996,2780},{2045,2785},{2119,2788},{1951,2789},{2165,2792},{2087,2798},{2114,2804},{2064,2806},{2074,2809},{1313,2810},{2158,2814},{2072,2816},{2126,2826},{1875,2830},{2038,2832},{2125,2834},{1374,2836},{1350,2840},{2173,2843},{2187,2846},{2079,2850},{2084,2856},{2155,2862},{2110,2864},{2151,2869},{2170,2873},{1852,2879},{2147,2881},{2139,2882},{2113,2883},{2102,2891},{2124,2899},{2069,2902},{2212,2905},{1797,2910},{2200,2915},{2179,2917},{2160,2919},{2122,2921},{2121,2925},{2178,2927},{1961,2931},{2020,2938},{2167,2943},{2219,2946},{1968,2953},{1645,2954},{2090,2956},{1827,2957},{2236,2960},{2154,2970},{2233,2972},{2244,2974},{2260,2979},{1427,2981},{2189,2985},{1980,2986},{2265,2993},{2228,2997},{2249,3001},{2275,3004},{2270,3006},{2242,3007},{2328,3012},{2227,3015},{2172,3020},{2214,3024},{2253,3026},{2285,3031},{2274,3032},{2208,3036},{2061,3037},{2150,3039},{2267,3046},{2028,3048},{2295,3057},{2241,3061},{2232,3064},{2207,3067},{2006,3078},{2321,3082},{2301,3084},{2252,3089},{2280,3097},{2259,3099},{2354,3101},{2417,3103},{2380,3106},{2258,3110},{2331,3113},{2431,3116},{2324,3117},{2312,3118},{2248,3119},{2044,3121},{2306,3125},{2316,3128},{2308,3130},{2109,3138},{2344,3145},{2251,3148},{1748,3156},{1559,3159},{2305,3163},{2384,3169},{2290,3172},{2374,3177},{2413,3179},{2392,3182},{2409,3190},{2300,3193},{2353,3197},{2383,3201},{2334,3202},{2465,3206},{2083,3207},{2379,3213},{2361,3217},{2320,3218},{2434,3225},{2226,3229},{2452,3232},{1734,3235},{2561,3241},{2197,3244},{2472,3246},{2373,3247},{2326,3250},{1801,3252},{2082,3254},{2423,3258},{2221,3261},{2446,3269},{1861,3273},{2451,3281},{2484,3286},{2479,3287},{2372,3289},{2489,3294},{2488,3297},{2475,3299},{2443,3302},{1523,3303},{2587,3312},{2387,3314},{2442,3317},{2537,3323},{2499,3325},{2441,3327},{2292,3333},{2131,3334},{1686,3335},{2273,3338},{2433,3341},{2586,3343},{2482,3345},{2521,3350},{2457,3351},{2508,3355},{2507,3358},{2408,3359},{2654,3367},{2529,3368},{2595,3372},{2520,3374},{2582,3377},{2533,3379},{2519,3381},{2501,3384},{1596,3385},{2555,3391},{2429,3393},{2554,3395},{2343,3396},{2544,3405},{2594,3409},{2532,3412},{2467,3413},{2626,3418},{2569,3422},{2360,3423},{2314,3425},{2263,3433},{2518,3441},{2652,3449},{2581,3454},{2580,3459},{2304,3460},{2638,3463},{2609,3464},{2599,3466},{2579,3467},{2527,3471},{2585,3475},{2186,3478},{2637,3480},{2543,3488},{2498,3495},{2487,3498},{2481,3500},{2566,3502},{2664,3506},{2630,3508},{2563,3510},{2419,3512},{2606,3518},{2352,3519},{2621,3525},{2680,3529},{2535,3534},{2578,3536},{2560,3538},{2542,3544},{2651,3547},{2718,3549},{2461,3552},{2602,3558},{1632,3560},{2696,3565},{2659,3569},{2340,3570},{2629,3578},{2656,3584},{2371,3585},{2279,3589},{2559,3592},{2478,3598},{2723,3600},{2620,3601},{2619,3605},{2694,3614},{2712,3619},{2644,3621},{2618,3628},{2726,3635},{2699,3638},{2706,3640},{2717,3643},{2742,3647},{2737,3651},{2791,3656},{2679,3658},{2715,3665},{2636,3667},{2650,3671},{2757,3673},{2741,3676},{2782,3681},{2584,3684},{2736,3689},{2541,3693},{2765,3698},{2574,3699},{2802,3704},{2775,3705},{2771,3709},{1816,3712},{2795,3714},{2756,3719},{2678,3720},{2590,3722},{2829,3724},{2732,3727},{2378,3731},{2801,3733},{2867,3737},{2625,3739},{2818,3743},{2677,3748},{2825,3756},{2735,3759},{2800,3762},{2349,3763},{2876,3767},{2808,3769},{2823,3771},{2667,3772},{2861,3776},{2855,3777},{2860,3781},{2813,3787},{2839,3793},{2968,3795},{2941,3798},{2898,3801},{2866,3809},{2397,3810},{2144,3811},{2728,3814},{3076,3821},{2909,3822},{2853,3824},{2767,3825},{2740,3832},{2895,3835},{2540,3838},{2940,3841},{2698,3844},{2812,3848},{2731,3852},{2820,3854},{975,3859},{2794,3862},{2477,3864},{2930,3872},{3066,3877},{2889,3880},{2859,3882},{2849,3886},{2845,3888},{2784,3890},{2967,3896},{2745,3898},{2886,3900},{2875,3907},{2211,3908},{3030,3914},{2912,3916},{2753,3917},{2964,3921},{2936,3923},{2553,3924},{2929,3927},{2848,3932},{2907,3935},{2504,3941},{2950,3944},{2948,3948},{3011,3952},{2858,3955},{2797,3957},{3055,3961},{2996,3965},{2978,3966},{2914,3971},{2770,3974},{2711,3977},{2977,3982},{1868,3991},{2901,3995},{2983,3998},{2838,3999},{3017,4010},{2893,4011},{2777,4012},{3051,4016},{3010,4017},{2693,4018},{3150,4026},{2952,4027},{1931,4030},{3081,4033},{3019,4037},{2364,4038},{2878,4044},{3060,4049},{3043,4051},{2763,4052},{2157,4055},{3074,4057},{3000,4060},{3187,4068},{3035,4070},{2995,4074},{2828,4075},{1908,4079},{2991,4081},{2966,4082},{2649,4089},{3053,4097},{3087,4100},{3023,4103},{3034,4107},{2924,4109},{3041,4111},{3123,4119},{3094,4120},{2990,4121},{2615,4125},{3045,4128},{2934,4135},{2959,4138},{3086,4140},{3029,4141},{3137,4146},{3072,4150},{2976,4151},{2945,4152},{2497,4154},{2963,4160},{2714,4162},{3280,4165},{3153,4169},{3212,4172},{3127,4173},{3028,4176},{3542,4181},{3165,4182},{3133,4184},{2872,4186},{2933,4192},{3136,4195},{2923,4197},{2962,4199},{3147,4209},{3143,4210},{3093,4219},{3115,4222},{3096,4223},{2989,4231},{3092,4234},{3009,4237},{2448,4240},{3158,4243},{3195,4247},{3050,4249},{3152,4253},{3211,4261},{3140,4262},{3080,4263},{3278,4270},{3175,4271},{3162,4272},{3216,4277},{3069,4278},{3320,4288},{3265,4290},{3189,4291},{3192,4296},{3331,4298},{3181,4300},{3003,4302},{3239,4305},{3204,4307},{3272,4310},{3215,4314},{3337,4317},{3221,4319},{3105,4324},{3063,4330},{2904,4336},{3209,4338},{3285,4341},{3220,4343},{3257,4345},{3199,4348},{3275,4356},{3168,4361},{2999,4363},{3400,4372},{3234,4373},{3237,4375},{3361,4383},{3310,4384},{2871,4390},{3184,4395},{3432,4398},{3387,4399},{3329,4416},{3231,4425},{3607,4428},{3132,4429},{3404,4434},{3453,4437},{3383,4438},{3309,4442},{3014,4443},{3228,4446},{3091,4447},{3108,4449},{3308,4452},{3306,4453},{3249,4454},{3316,4466},{3399,4468},{3256,4471},{3293,4473},{3430,4478},{2725,4479},{3438,4487},{3407,4489},{3291,4493},{3227,4495},{3112,4503},{3224,4506},{2425,4507},{3322,4511},{3357,4519},{3364,4522},{3349,4523},{3366,4525},{3283,4526},{3243,4528},{3398,4532},{3277,4539},{3171,4543},{3296,4546},{3268,4547},{3271,4549},{2852,4550},{3371,4552},{3402,4559},{3167,4563},{3452,4567},{3443,4571},{1697,4572},{3469,4578},{3411,4579},{3264,4581},{3596,4586},{2035,4593},{3458,4595},{3448,4599},{3436,4601},{3429,4605},{2787,4608},{3260,4610},{2663,4619},{3486,4621},{3390,4622},{3483,4628},{3421,4631},{3348,4635},{3568,4644},{3370,4650},{3613,4652},{3521,4657},{3482,4660},{3347,4663},{3447,4670},{3492,4674},{3446,4675},{3301,4678},{3497,4681},{3174,4683},{3435,4690},{3428,4691},{3059,4700},{3562,4705},{2118,4706},{3477,4708},{3440,4712},{3491,4717},{3532,4722},{3417,4725},{3750,4732},{3485,4733},{3577,4740},{3515,4742},{3354,4744},{2842,4745},{3517,4751},{3528,4761},{3524,4763},{3625,4765},{3580,4768},{3663,4771},{3595,4772},{3551,4773},{3686,4775},{3583,4778},{2988,4779},{2897,4782},{3574,4786},{3540,4789},{3609,4801},{3457,4803},{2053,4805},{3634,4807},{3494,4809},{3415,4810},{3645,4814},{2722,4815},{3594,4818},{3623,4821},{3557,4832},{3514,4836},{3603,4839},{3637,4845},{3505,4847},{3555,4850},{3474,4856},{3669,4865},{3617,4871},{3527,4876},{3662,4878},{3490,4882},{3675,4888},{3612,4889},{3473,4892},{3427,4897},{3717,4903},{3655,4907},{3389,4914},{3576,4921},{3633,4926},{3591,4928},{3726,4932},{3631,4935},{3616,4939},{3567,4941},{3462,4945},{3692,4948},{3753,4953},{3680,4956},{3654,4959},{3588,4967},{3531,4969},{3661,4972},{3642,4977},{3582,4979},{3223,4992},{3742,5000}};

unordered_map<int,int> Map;
void init(){
    int k = 0;
    Map[3742] = 5000;
    while(!(G[k][0]==3742&&G[k][1]==5000)){
        if(Map.find(G[k][0])!=Map.end()){
            throw runtime_error("repeated keys");
        }
        Map[G[k][0]] = G[k][1];
        ++k;
    }
}

inline int f(int n,int m){
    auto it = Map.find(n);
    return it!=Map.end()&&it->se==m ? 1 : 0;
}

int main(){
    init();
    int n,m,nofkase = getUnsigned();
    while(nofkase--){
        n = getUnsigned();
        m = getUnsigned();
        if(n>m) swap(n,m);
        puts(f(n,m)?"Bob":"Alice");
    }
    return 0;
}
